﻿@model Mvc.Sample.Models.TodoItem

@{
    ViewData["Title"] = "Details";
}

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8" />
    <title>@Model.Title Details</title>
    <link href="~/lib/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet" />
    <link href="~/lib/bootstrap-icons/font/bootstrap-icons.min.css" rel="stylesheet" />
</head>
<body>
    <div class="container mt-5">
        <h2 class="text-center">
            Details
        </h2>
        <hr />
        <div class="row">
            <div class="col-md-6 offset-md-3">
                <table class="table table-striped">
                    <tbody>
                        <tr>
                            <th>
                                <i class="bi bi-tag fs-6 align-text-bottom me-1"></i>
                                ID
                            </th>
                            <td>@Model.Id</td>
                        </tr>
                        <tr>
                            <th>
                                <i class="bi bi-card-heading fs-6 align-text-bottom me-1"></i>
                                Title
                            </th>
                            <td>@Model.Title</td>
                        </tr>
                        <tr>
                            <th>
                                <i class="bi bi-file-text fs-6 align-text-bottom me-1"></i>
                                Description
                            </th>
                            <td>@Model.Description</td>
                        </tr>
                        <tr>
                            <th>
                                <i class="bi @(Model.IsDone ? "bi-check-circle-fill text-success" : "bi-x-circle-fill text-danger") fs-6 align-text-bottom me-1"></i>
                                Is Done
                            </th>
                            <td>@(Model.IsDone ? "Yes" : "No")</td>
                        </tr>
                        <tr>
                            <th>
                                <i class="bi bi-calendar-event fs-6 align-text-bottom me-1"></i>
                                Due Date
                            </th>
                            <td>@Model.DueDate.ToShortDateString()</td>
                        </tr>
                    </tbody>
                </table>
                <div>
	                @Html.ActionLink("Back to List", "Index", "Home", new { @class = "btn btn-secondary" })
                </div>
            </div>
        </div>
    </div>
    <script src="~/lib/jquery/dist/jquery.js"></script>
    <script src="~/lib/bootstrap/dist/js/bootstrap.bundle.min.js"></script>
</body>
</html>
